package org.yocastlong.mybatisplus.db.domain;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * <p>
 * 订单表
 * </p>
 *
 * @author castlong
 * @since 2025-06-06
 */
@Data
@TableName("t_order")
public class OrderDO implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 订单id
     */
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private String id;

    /**
     * 商品id
     */
    private String goodsId;

    /**
     * 商品名
     */
    private String goodsName;

    /**
     * 快照版本
     */
    private Integer goodsSnapshotVersion;

    /**
     * 商品价格
     */
    private String goodsPrice;

    /**
     * 用户id
     */
    private String userId;

    /**
     * 用户名
     */
    private String username;

    private String areaCode;

    private String areaName;

    @TableField(fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    @TableField(fill = FieldFill.INSERT)
    private LocalDateTime createTime;

}
